Optimal. Leaf size=69 \[ \frac {\left (a+b \tanh ^{-1}\left (c \sqrt {x}\right )\right )^2}{b}+2 \left (a+b \tanh ^{-1}\left (c \sqrt {x}\right )\right ) \log \left (2-\frac {2}{1+c \sqrt {x}}\right )-b \text {PolyLog}\left (2,-1+\frac {2}{1+c \sqrt {x}}\right ) \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.18, antiderivative size = 69, normalized size of antiderivative = 1.00, number of steps
used = 5, number of rules used = 7, integrand size = 26, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.269, Rules used = {36, 29, 31,
1607, 6135, 6079, 2497} \begin {gather*} \frac {\left (a+b \tanh ^{-1}\left (c \sqrt {x}\right )\right )^2}{b}+2 \log \left (2-\frac {2}{c \sqrt {x}+1}\right ) \left (a+b \tanh ^{-1}\left (c \sqrt {x}\right )\right )-b \text {Li}_2\left (\frac {2}{\sqrt {x} c+1}-1\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 29
Rule 31
Rule 36
Rule 1607
Rule 2497
Rule 6079
Rule 6135
Rubi steps
\begin {align*} \int \frac {a+b \tanh ^{-1}\left (c \sqrt {x}\right )}{x \left (1-c^2 x\right )} \, dx &=2 \text {Subst}\left (\int \frac {a+b \tanh ^{-1}(c x)}{x-c^2 x^3} \, dx,x,\sqrt {x}\right )\\ &=2 \text {Subst}\left (\int \frac {a+b \tanh ^{-1}(c x)}{x \left (1-c^2 x^2\right )} \, dx,x,\sqrt {x}\right )\\ &=\frac {\left (a+b \tanh ^{-1}\left (c \sqrt {x}\right )\right )^2}{b}+2 \text {Subst}\left (\int \frac {a+b \tanh ^{-1}(c x)}{x (1+c x)} \, dx,x,\sqrt {x}\right )\\ &=\frac {\left (a+b \tanh ^{-1}\left (c \sqrt {x}\right )\right )^2}{b}+2 \left (a+b \tanh ^{-1}\left (c \sqrt {x}\right )\right ) \log \left (2-\frac {2}{1+c \sqrt {x}}\right )-(2 b c) \text {Subst}\left (\int \frac {\log \left (2-\frac {2}{1+c x}\right )}{1-c^2 x^2} \, dx,x,\sqrt {x}\right )\\ &=\frac {\left (a+b \tanh ^{-1}\left (c \sqrt {x}\right )\right )^2}{b}+2 \left (a+b \tanh ^{-1}\left (c \sqrt {x}\right )\right ) \log \left (2-\frac {2}{1+c \sqrt {x}}\right )-b \text {Li}_2\left (-1+\frac {2}{1+c \sqrt {x}}\right )\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.08, size = 72, normalized size = 1.04 \begin {gather*} b \tanh ^{-1}\left (c \sqrt {x}\right ) \left (\tanh ^{-1}\left (c \sqrt {x}\right )+2 \log \left (1-e^{-2 \tanh ^{-1}\left (c \sqrt {x}\right )}\right )\right )+a \log (x)-a \log \left (1-c^2 x\right )-b \text {PolyLog}\left (2,e^{-2 \tanh ^{-1}\left (c \sqrt {x}\right )}\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(216\) vs.
\(2(61)=122\).
time = 0.25, size = 217, normalized size = 3.14
method | result | size |
derivativedivides | \(-a \ln \left (1+c \sqrt {x}\right )-a \ln \left (c \sqrt {x}-1\right )+2 a \ln \left (c \sqrt {x}\right )-b \arctanh \left (c \sqrt {x}\right ) \ln \left (1+c \sqrt {x}\right )-b \arctanh \left (c \sqrt {x}\right ) \ln \left (c \sqrt {x}-1\right )+2 b \arctanh \left (c \sqrt {x}\right ) \ln \left (c \sqrt {x}\right )-b \dilog \left (1+c \sqrt {x}\right )-b \ln \left (c \sqrt {x}\right ) \ln \left (1+c \sqrt {x}\right )-b \dilog \left (c \sqrt {x}\right )-\frac {b \ln \left (c \sqrt {x}-1\right )^{2}}{4}+b \dilog \left (\frac {c \sqrt {x}}{2}+\frac {1}{2}\right )+\frac {b \ln \left (c \sqrt {x}-1\right ) \ln \left (\frac {c \sqrt {x}}{2}+\frac {1}{2}\right )}{2}+\frac {b \ln \left (1+c \sqrt {x}\right )^{2}}{4}+\frac {b \ln \left (-\frac {c \sqrt {x}}{2}+\frac {1}{2}\right ) \ln \left (\frac {c \sqrt {x}}{2}+\frac {1}{2}\right )}{2}-\frac {b \ln \left (-\frac {c \sqrt {x}}{2}+\frac {1}{2}\right ) \ln \left (1+c \sqrt {x}\right )}{2}\) | \(217\) |
default | \(-a \ln \left (1+c \sqrt {x}\right )-a \ln \left (c \sqrt {x}-1\right )+2 a \ln \left (c \sqrt {x}\right )-b \arctanh \left (c \sqrt {x}\right ) \ln \left (1+c \sqrt {x}\right )-b \arctanh \left (c \sqrt {x}\right ) \ln \left (c \sqrt {x}-1\right )+2 b \arctanh \left (c \sqrt {x}\right ) \ln \left (c \sqrt {x}\right )-b \dilog \left (1+c \sqrt {x}\right )-b \ln \left (c \sqrt {x}\right ) \ln \left (1+c \sqrt {x}\right )-b \dilog \left (c \sqrt {x}\right )-\frac {b \ln \left (c \sqrt {x}-1\right )^{2}}{4}+b \dilog \left (\frac {c \sqrt {x}}{2}+\frac {1}{2}\right )+\frac {b \ln \left (c \sqrt {x}-1\right ) \ln \left (\frac {c \sqrt {x}}{2}+\frac {1}{2}\right )}{2}+\frac {b \ln \left (1+c \sqrt {x}\right )^{2}}{4}+\frac {b \ln \left (-\frac {c \sqrt {x}}{2}+\frac {1}{2}\right ) \ln \left (\frac {c \sqrt {x}}{2}+\frac {1}{2}\right )}{2}-\frac {b \ln \left (-\frac {c \sqrt {x}}{2}+\frac {1}{2}\right ) \ln \left (1+c \sqrt {x}\right )}{2}\) | \(217\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [B] Leaf count of result is larger than twice the leaf count of optimal. 159 vs.
\(2 (60) = 120\).
time = 0.37, size = 159, normalized size = 2.30 \begin {gather*} -\frac {1}{4} \, b \log \left (c \sqrt {x} + 1\right )^{2} + \frac {1}{2} \, b \log \left (c \sqrt {x} + 1\right ) \log \left (-c \sqrt {x} + 1\right ) + \frac {1}{4} \, b \log \left (-c \sqrt {x} + 1\right )^{2} - {\left (\log \left (c \sqrt {x} + 1\right ) \log \left (-\frac {1}{2} \, c \sqrt {x} + \frac {1}{2}\right ) + {\rm Li}_2\left (\frac {1}{2} \, c \sqrt {x} + \frac {1}{2}\right )\right )} b - {\left (\log \left (c \sqrt {x}\right ) \log \left (-c \sqrt {x} + 1\right ) + {\rm Li}_2\left (-c \sqrt {x} + 1\right )\right )} b + {\left (\log \left (c \sqrt {x} + 1\right ) \log \left (-c \sqrt {x}\right ) + {\rm Li}_2\left (c \sqrt {x} + 1\right )\right )} b - a {\left (\log \left (c \sqrt {x} + 1\right ) + \log \left (c \sqrt {x} - 1\right ) - \log \left (x\right )\right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} - \int \frac {a}{c^{2} x^{2} - x}\, dx - \int \frac {b \operatorname {atanh}{\left (c \sqrt {x} \right )}}{c^{2} x^{2} - x}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} -\int \frac {a+b\,\mathrm {atanh}\left (c\,\sqrt {x}\right )}{x\,\left (c^2\,x-1\right )} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________